<template>
  <nav>
    <router-link active-class="selected" class="item" to="/money">
      <Icon name="money"/>
      <span>记账</span>
    </router-link>
    <router-link active-class="selected" class="item" to="/labels">
      <Icon name="label"/>
      <span>标签</span>
    </router-link>
    <router-link active-class="selected" class="item" to="/statistics">
      <Icon name="statistics"/>
      <span>统计</span>
    </router-link>
  </nav>
</template>

<script lang="ts">
export default {
  name: 'Nav'
};
</script>

<style lang="scss" scoped>
@import "~@/assets/style/helper.scss";

nav {
  @extend %outerShadow;
  position: fixed;
  max-width: 500px;
  width: 100%;
  bottom: 0;
  display: flex;
  flex-direction: row;
  font-size: 12px;
  background-color: white;

  > .item {
    width: 33.33333%;
    padding: 2px 0;
    display: flex;
    justify-content: center;
    text-align: center;
    align-items: center;
    flex-direction: column;
    color: rgba(191, 191, 191, 1);

    .icon {
      width: 30px;
      height: 30px;
    }
  }

  > .selected {
    color: $color-highlight;
  }
}
</style>
